package com.study.portal.service.impl;

import java.util.List;

import com.study.portal.dao.INavDao;
import com.study.portal.pojo.system.Nav;
import com.study.portal.service.INavService;

public class NavServiceImpl implements INavService {

	private INavDao navDao;
	
	public void setNavDao(INavDao navDao) {
		this.navDao = navDao;
	}

	public List<Nav> select(Nav searchFrom) {
		return this.navDao.select(searchFrom);
	}

	public Nav get(String id) {
		return this.navDao.get(id);
	}

	public void insert(Nav nav) {
		this.navDao.insert(nav);
	}

	public void update(Nav nav) {
		this.navDao.update(nav);
	}

	public void changeUseStatus(Nav nav) {
		Nav nav2 = new Nav();
		nav2.setId(nav.getId());
		nav2.setIsUse(nav.getIsUse());
		this.navDao.update(nav2);
	}

}
